package com.lyy.system.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.lyy.system.entity.Log;
import com.lyy.system.mapper.LogMapper;
import com.lyy.system.service.LogService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class LogServiceImpl extends ServiceImpl<LogMapper, Log> implements LogService {

    @Autowired
    private LogMapper logMapper;

    @Override
    public void saveLog(Log log) {
        this.baseMapper.insert(log);
    }

    @Override
    public IPage<Log> queryLogList(Page<Log> page, QueryWrapper<Log> wrapper) {
        return this.baseMapper.queryLogList(page,wrapper);
    }

    @Override
    public void delLogById(Long id) {
        this.baseMapper.deleteById(id);
    }
}
